using IcsSEMCtrl.Global;
using IcsSEMCtrl.Util.Client;
using Lifter.Device;
using Lifter.Utility;
using Sunny.UI;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.ComponentModel;
using System.Configuration;
using System.Drawing;
using System.IO;
using System.Text;
using System.Threading;
using System.Windows.Forms;
using TKT.Lifter.CIM.Lifter.Global;
using TKT.Lifter.CIM.Lifter.Gui.Monitor.Popups;

namespace Lifter.Gui.Monitor.Panels
{
    public class InformOperation : InformLogMenu
    {
        private delegate void LogReadDelegate();
        private delegate void AddDataGrid(string readString);
        private Thread threadSearch = null;
        private IContainer components = null;
        private DataGridView dataGridView;
        private Panel panelProgress;
        private Sunny.UI.UIPanel panelSearch;
        private DateTimePicker ToDayPicker;
        private DateTimePicker fromDayPicker;
        private Sunny.UI.UISymbolButton buttonSearch;
        private Sunny.UI.UITextBox txtTarget;
        private Sunny.UI.UIMarkLabel uiMarkLabel1;
        private Sunny.UI.UIMarkLabel uiMarkLabel2;
        private Sunny.UI.UISymbolButton buttonSaveToCVS;
        private Sunny.UI.UIPanel uiPanel1;
        private Label labelMessage;
        private string saveFilePath = "";
        public InformOperation()
        {
            this.InitializeComponent();
            this.InitializeDataGrid();
            this.fromDayPicker.Value = DateTime.Now;
            this.ToDayPicker.Value = DateTime.Now;
        }
        private void InitializeDataGrid()
        {
            try
            {
                this.dataGridView.AllowUserToAddRows = true;
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns.Add(new DataGridViewTextBoxColumn());
                this.dataGridView.Columns[0].HeaderText = "Date & Time";
                this.dataGridView.Columns[1].HeaderText = "Type";
                this.dataGridView.Columns[2].HeaderText = "CMD.ID";
                this.dataGridView.Columns[3].HeaderText = "CarrierID";
                this.dataGridView.Columns[4].HeaderText = "CarrierType";
                this.dataGridView.Columns[5].HeaderText = "Carrier LOC.";
                this.dataGridView.Columns[6].HeaderText = "Source";
                this.dataGridView.Columns[7].HeaderText = "Destination";
                this.dataGridView.Columns[8].HeaderText = "From";
                this.dataGridView.Columns[9].HeaderText = "To";
                this.dataGridView.Columns[10].HeaderText = "Next.LOC";
                this.dataGridView.Columns[0].Width = 160;
                this.dataGridView.Columns[1].Width = 60;
                this.dataGridView.Columns[2].Width = 120;
                this.dataGridView.Columns[3].Width = 120;
                this.dataGridView.Columns[4].Width = 80;
                this.dataGridView.Columns[5].Width = 100;
                this.dataGridView.Columns[6].Width = 100;
                this.dataGridView.Columns[7].Width = 100;
                this.dataGridView.Columns[8].Width = 60;
                this.dataGridView.Columns[9].Width = 60;
                this.dataGridView.Columns[10].Width = 100;
                this.dataGridView.RowsDefaultCellStyle.WrapMode = DataGridViewTriState.False;
                this.dataGridView.AllowUserToAddRows = false;
            }
            catch (Exception)
            {
            }
        }
        private void buttonSearch_Click(object sender, EventArgs e)
        {
            if (this.threadSearch == null)
            {
                this.threadSearch = new Thread(new ThreadStart(this.CommandLogRead));
            }
            if (this.threadSearch.ThreadState != ThreadState.Running)
            {
                if (this.threadSearch.ThreadState == ThreadState.Stopped)
                {
                    this.threadSearch = new Thread(new ThreadStart(this.CommandLogRead));
                    this.threadSearch.Start();
                }
                else
                {
                    if (this.threadSearch.ThreadState == ThreadState.Stopped)
                    {
                        this.threadSearch.Start();
                    }
                    else
                    {
                        if (this.threadSearch.ThreadState == ThreadState.Unstarted)
                        {
                            this.threadSearch.Start();
                        }
                    }
                }
            }
        }
        private void Search()
        {
            base.BeginInvoke(new InformOperation.LogReadDelegate(this.CommandLogRead));
        }
        private void StartSearch()
        {
            this.panelProgress.BringToFront();
            this.labelMessage.Text = "正在查找数据。请稍等片刻。";
            this.dataGridView.Rows.Clear();
            this.dataGridView.Enabled = false;
            this.panelSearch.Enabled = false;
        }
        private void EndSearch()
        {
            this.panelSearch.Enabled = true;
            this.dataGridView.Enabled = true;
            this.panelProgress.SendToBack();
            this.dataGridView.Sort(this.dataGridView.Columns[0], ListSortDirection.Descending);
            foreach (DataGridViewRow dataGridViewRow in this.dataGridView.SelectedRows)
            {
                dataGridViewRow.Selected = false;
            }
        }
        private void StartSave()
        {
            this.panelProgress.BringToFront();
            this.labelMessage.Text = "正在存储数据。稍等片刻.";
            this.dataGridView.Enabled = false;
            this.panelSearch.Enabled = false;
        }
        private void EndSave()
        {
            this.panelSearch.Enabled = true;
            this.panelSearch.Enabled = true;
            this.dataGridView.Enabled = true;
            this.panelProgress.SendToBack();
        }
        private void CommandLogRead()
        {
            try
            {
                base.BeginInvoke(new InformOperation.LogReadDelegate(this.StartSearch));
                NameValueCollection appSettings = ConfigurationManager.AppSettings;
                string path = appSettings[ECPProperties.ECP_LOG].ToString() + "\\Log\\Statistics\\PLC";
                List<FileInfo> filesForReading = this.GetFilesForReading(path);
                foreach (FileInfo current in filesForReading)
                {
                    StringBuilder stringBuilder = new StringBuilder();
                    using (StreamReader streamReader = new StreamReader(new FileStream(current.FullName, FileMode.Open, FileAccess.Read, FileShare.ReadWrite)))
                    {
                        if (streamReader == null || current.Length == 0L)
                        {
                            continue;
                        }
                        stringBuilder = new StringBuilder(streamReader.ReadToEnd());
                    }
                    if (stringBuilder != null)
                    {
                        string[] array = stringBuilder.ToString().Split(new char[]
                        {
                            '\n'
                        });
                        for (int i = 0; i < array.Length; i++)
                        {
                            string text = array[i];
                            if (text != null)
                            {
                                if (string.IsNullOrEmpty(this.txtTarget.Text) || text.ToUpper().Contains(this.txtTarget.Text.ToUpper()))
                                {
                                    object[] args = new object[]
                                    {
                                        text
                                    };
                                    base.BeginInvoke(new InformOperation.AddDataGrid(this.AddLogData), args);
                                }
                            }
                        }
                    }
                }
                base.BeginInvoke(new InformOperation.LogReadDelegate(this.EndSearch));
            }
            catch (Exception e)
            {
                PopupNotice.DialogPopups(e.Message, e.Message, enumPopupsType.Error);
                base.BeginInvoke(new InformOperation.LogReadDelegate(this.EndSearch));
            }
        }
        private void AddLogData(string readString)
        {
            string[] array = readString.Split(new char[]
            {
                '/'
            });
            try
            {
                DataGridViewRow dataGridViewRow = new DataGridViewRow();
                if (array.Length >= 8)
                {
                    int index = this.dataGridView.Rows.Add(dataGridViewRow);
                    for (int i = 0; i < array.Length; i++)
                    {
                        switch (i)
                        {
                            case 0:
                                this.dataGridView.Rows[index].Cells[0].Value = array[0];
                                break;
                            case 1:
                                if (array[1].Trim() == "PLC")
                                {
                                    this.dataGridView.Rows[index].Cells[1].Value = array[1];
                                    DataGridViewCellStyle dataGridViewCellStyle = new DataGridViewCellStyle();
                                    dataGridViewCellStyle.BackColor = Color.Green;
                                    this.dataGridView.Rows[index].Cells[1].Style = dataGridViewCellStyle;
                                }
                                else
                                {
                                    this.dataGridView.Rows[index].Cells[1].Value = array[1];
                                    DataGridViewCellStyle dataGridViewCellStyle = new DataGridViewCellStyle();
                                    dataGridViewCellStyle.BackColor = Color.Crimson;
                                    this.dataGridView.Rows[index].Cells[1].Style = dataGridViewCellStyle;
                                }
                                break;
                            case 2:
                                {
                                    this.dataGridView.Rows[index].Cells[2].Value = array[2];
                                    int num = 0;
                                    if (int.TryParse(array[2], out num))
                                    {
                                        num %= 50;
                                    }
                                    else
                                    {
                                        num = 0;
                                    }
                                    DataGridViewCellStyle dataGridViewCellStyle2 = new DataGridViewCellStyle();
                                    int red = (int)((byte)((120 + num * 3) % 255));
                                    int green = (int)((byte)((120 - num * 3) % 255));
                                    int blue = (int)((byte)((120 * num + num) % 255));
                                    dataGridViewCellStyle2.BackColor = Color.FromArgb(red, green, blue);
                                    this.dataGridView.Rows[index].Cells[2].Style = dataGridViewCellStyle2;
                                    break;
                                }
                            case 3:
                                {
                                    this.dataGridView.Rows[index].Cells[6].Value = array[3];
                                    DataGridViewCellStyle dataGridViewCellStyle3 = new DataGridViewCellStyle();
                                    dataGridViewCellStyle3.BackColor = Color.BurlyWood;
                                    this.dataGridView.Rows[index].Cells[6].Style = dataGridViewCellStyle3;
                                    break;
                                }
                            case 4:
                                {
                                    this.dataGridView.Rows[index].Cells[7].Value = array[4];
                                    DataGridViewCellStyle dataGridViewCellStyle4 = new DataGridViewCellStyle();
                                    dataGridViewCellStyle4.BackColor = Color.Gold;
                                    this.dataGridView.Rows[index].Cells[7].Style = dataGridViewCellStyle4;
                                    break;
                                }
                            case 5:
                                {
                                    this.dataGridView.Rows[index].Cells[8].Value = array[5];
                                    DataGridViewCellStyle dataGridViewCellStyle5 = new DataGridViewCellStyle();
                                    dataGridViewCellStyle5.BackColor = Color.BurlyWood;
                                    this.dataGridView.Rows[index].Cells[8].Style = dataGridViewCellStyle5;
                                    break;
                                }
                            case 6:
                                {
                                    this.dataGridView.Rows[index].Cells[9].Value = array[6];
                                    DataGridViewCellStyle dataGridViewCellStyle6 = new DataGridViewCellStyle();
                                    dataGridViewCellStyle6.BackColor = Color.Gold;
                                    this.dataGridView.Rows[index].Cells[9].Style = dataGridViewCellStyle6;
                                    break;
                                }
                            case 7:
                                this.dataGridView.Rows[index].Cells[5].Value = array[7];
                                break;
                            case 8:
                                this.dataGridView.Rows[index].Cells[10].Value = array[8];
                                break;
                            case 9:
                                this.dataGridView.Rows[index].Cells[3].Value = array[9];
                                break;
                            case 10:
                                {
                                    this.dataGridView.Rows[index].Cells[4].Value = array[10];
                                    DataGridViewCellStyle dataGridViewCellStyle7 = new DataGridViewCellStyle();
                                    dataGridViewCellStyle7.BackColor = Color.White;
                                    if (array[10].Trim() == "AGV")
                                    {
                                        dataGridViewCellStyle7.BackColor = Color.LightGreen;
                                    }
                                    else
                                    {
                                        if (array[10].Trim() == "FULL")
                                        {
                                            dataGridViewCellStyle7.BackColor = Color.LightCoral;
                                        }
                                        else
                                        {
                                            if (array[10].Trim() == "EMPTY")
                                            {
                                                dataGridViewCellStyle7.BackColor = Color.LightBlue;
                                            }
                                            else
                                            {
                                                if (array[10].Trim() == "ERROR")
                                                {
                                                    dataGridViewCellStyle7.BackColor = Color.DarkRed;
                                                }
                                                else
                                                {
                                                    if (array[10].Trim() == "CLEAN")
                                                    {
                                                        dataGridViewCellStyle7.BackColor = Color.Cyan;
                                                    }
                                                }
                                            }
                                        }
                                    }
                                    this.dataGridView.Rows[index].Cells[4].Style = dataGridViewCellStyle7;
                                    break;
                                }
                        }
                    }
                }
            }
            catch (Exception)
            {
            }
            finally
            {
            }
        }
        private List<FileInfo> GetFilesForReading(string path)
        {
            FileInfo[] files = new DirectoryInfo(path).GetFiles("PLC-*.log");
            List<FileInfo> list = new List<FileInfo>();
            DateTimeConverter dateTimeConverter = new DateTimeConverter();
            DateTime dateTime = (DateTime)dateTimeConverter.ConvertFromString(this.fromDayPicker.Text);
            DateTime dateTime2 = (DateTime)dateTimeConverter.ConvertFromString(this.ToDayPicker.Text);
            while (dateTime.Ticks <= dateTime2.Ticks)
            {
                FileInfo[] array = files;
                for (int i = 0; i < array.Length; i++)
                {
                    FileInfo fileInfo = array[i];
                    if (fileInfo.Name.StartsWith("PLC-" + dateTime.ToString("yyyy-MM-dd")))
                    {
                        list.Add(fileInfo);
                    }
                }
                dateTime = dateTime.AddDays(1.0);
            }
            list.Sort(new DinoComparer());
            if (list.Count > 30)
            {
                list.RemoveRange(0, list.Count - 30);
            }
            return list;
        }
        private void buttonSaveToCVS_Click(object sender, EventArgs e)
        {
            if (this.dataGridView.Rows.Count <= 0)
            {
                PopupNotice.DialogPopups("没有可保存的资料.", "No data to save", enumPopupsType.Warning);
            }
            else
            {
                if (this.dataGridView.SelectedRows.Count == 0)
                {
                    PopupNotice.DialogPopups("请选择要保存的部分。[CTRL-A]为全选.", "No data to save", enumPopupsType.Warning);
                }
                else
                {
                    string dir = "";
                    if (DirEx.SelectDirEx("选择保存文件路径", ref dir))
                    {
                        this.saveFilePath = dir;
                        new Thread(new ThreadStart(this.SaveToCVS)).Start();
                    }
                }
            }
        }
        private void txtTarget_KeyUp(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Return)
            {
                this.buttonSearch_Click(this, null);
            }
        }
        private void label4_Click(object sender, EventArgs e)
        {
            if (!this.panelSearch.Enabled)
            {
                this.panelSearch.Enabled = true;
            }
        }
        private void SaveToCVS()
        {
            base.BeginInvoke(new InformOperation.LogReadDelegate(this.StartSave));
            LifterSEM lifterSEM = (LifterSEM)Naming.GetDeviceManager().GetDevice();
            string text2 = lifterSEM.HostID + "_Command_" + DateTime.Now.ToString("yyyy-MM-dd HHmmssfff") + ".csv";
            try
            {
                if (!Directory.Exists(saveFilePath))
                {
                    Directory.CreateDirectory(saveFilePath);
                }
                using (StreamWriter streamWriter = new StreamWriter(new FileStream(saveFilePath + text2, FileMode.OpenOrCreate, FileAccess.Write, FileShare.ReadWrite)))
                {
                    StringBuilder stringBuilder = new StringBuilder();
                    foreach (DataGridViewRow dataGridViewRow in (IEnumerable)this.dataGridView.Rows)
                    {
                        if (dataGridViewRow.Selected)
                        {
                            string text3 = "";
                            foreach (DataGridViewCell dataGridViewCell in dataGridViewRow.Cells)
                            {
                                text3 = text3 + dataGridViewCell.Value + '\t';
                            }
                            streamWriter.WriteLine(text3.Trim());
                            Thread.Sleep(0);
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex.StackTrace);
                base.BeginInvoke(new InformOperation.LogReadDelegate(this.EndSave));
            }
            finally
            {
                base.BeginInvoke(new InformOperation.LogReadDelegate(this.EndSave));
            }
        }
        private void ToDayPicker_ValueChanged(object sender, EventArgs e)
        {
            DateTime value = this.fromDayPicker.Value;
            DateTime value2 = this.ToDayPicker.Value;
            if (value < value2.AddDays(-3.0))
            {
                this.fromDayPicker.Value = value2.AddDays(-3.0);
            }
            else
            {
                if (value > value2)
                {
                    this.fromDayPicker.Value = value2;
                }
            }
        }
        private void fromDayPicker_ValueChanged(object sender, EventArgs e)
        {
            DateTime value = this.fromDayPicker.Value;
            DateTime value2 = this.ToDayPicker.Value;
            if (value.AddDays(3.0) < value2)
            {
                this.ToDayPicker.Value = value.AddDays(3.0);
            }
            else
            {
                if (value > value2)
                {
                    this.ToDayPicker.Value = value;
                }
            }
        }
        private void InformOperation_Paint(object sender, PaintEventArgs e)
        {
            this.CommandLogRead();
        }
        protected override void Dispose(bool disposing)
        {
            if (disposing && this.components != null)
            {
                this.components.Dispose();
            }
            base.Dispose(disposing);
        }
        private void InitializeComponent()
        {
            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle();
            this.dataGridView = new System.Windows.Forms.DataGridView();
            this.panelProgress = new System.Windows.Forms.Panel();
            this.labelMessage = new System.Windows.Forms.Label();
            this.panelSearch = new Sunny.UI.UIPanel();
            this.buttonSaveToCVS = new Sunny.UI.UISymbolButton();
            this.uiMarkLabel2 = new Sunny.UI.UIMarkLabel();
            this.uiMarkLabel1 = new Sunny.UI.UIMarkLabel();
            this.ToDayPicker = new System.Windows.Forms.DateTimePicker();
            this.fromDayPicker = new System.Windows.Forms.DateTimePicker();
            this.buttonSearch = new Sunny.UI.UISymbolButton();
            this.txtTarget = new Sunny.UI.UITextBox();
            this.uiPanel1 = new Sunny.UI.UIPanel();
            ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
            this.panelProgress.SuspendLayout();
            this.panelSearch.SuspendLayout();
            this.uiPanel1.SuspendLayout();
            this.SuspendLayout();
            // 
            // dataGridView
            // 
            this.dataGridView.AllowUserToOrderColumns = true;
            dataGridViewCellStyle1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            dataGridViewCellStyle1.ForeColor = System.Drawing.Color.Black;
            dataGridViewCellStyle1.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
            dataGridViewCellStyle1.SelectionForeColor = System.Drawing.Color.White;
            this.dataGridView.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle1;
            this.dataGridView.BackgroundColor = System.Drawing.Color.AliceBlue;
            this.dataGridView.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
            this.dataGridView.CellBorderStyle = System.Windows.Forms.DataGridViewCellBorderStyle.SingleHorizontal;
            dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
            dataGridViewCellStyle2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
            dataGridViewCellStyle2.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.WindowText;
            dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Desktop;
            dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
            dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
            this.dataGridView.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle2;
            this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
            dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
            dataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Window;
            dataGridViewCellStyle3.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            dataGridViewCellStyle3.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(48)))), ((int)(((byte)(48)))), ((int)(((byte)(48)))));
            dataGridViewCellStyle3.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
            dataGridViewCellStyle3.SelectionForeColor = System.Drawing.Color.White;
            dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
            this.dataGridView.DefaultCellStyle = dataGridViewCellStyle3;
            this.dataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
            this.dataGridView.EditMode = System.Windows.Forms.DataGridViewEditMode.EditProgrammatically;
            this.dataGridView.GridColor = System.Drawing.Color.DarkGray;
            this.dataGridView.Location = new System.Drawing.Point(0, 0);
            this.dataGridView.Name = "dataGridView";
            this.dataGridView.ReadOnly = true;
            dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
            dataGridViewCellStyle4.BackColor = System.Drawing.Color.DimGray;
            dataGridViewCellStyle4.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            dataGridViewCellStyle4.ForeColor = System.Drawing.SystemColors.WindowText;
            dataGridViewCellStyle4.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
            dataGridViewCellStyle4.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
            dataGridViewCellStyle4.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
            this.dataGridView.RowHeadersDefaultCellStyle = dataGridViewCellStyle4;
            this.dataGridView.RowHeadersVisible = false;
            this.dataGridView.RowHeadersWidth = 20;
            this.dataGridView.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.DisableResizing;
            dataGridViewCellStyle5.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            dataGridViewCellStyle5.ForeColor = System.Drawing.Color.Black;
            dataGridViewCellStyle5.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
            dataGridViewCellStyle5.SelectionForeColor = System.Drawing.Color.White;
            dataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
            this.dataGridView.RowsDefaultCellStyle = dataGridViewCellStyle5;
            this.dataGridView.RowTemplate.DefaultCellStyle.Font = new System.Drawing.Font("Arial", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.dataGridView.RowTemplate.Height = 23;
            this.dataGridView.RowTemplate.ReadOnly = true;
            this.dataGridView.RowTemplate.Resizable = System.Windows.Forms.DataGridViewTriState.True;
            this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
            this.dataGridView.ShowCellErrors = false;
            //this.dataGridView.ShowCellToolTips = false;
            this.dataGridView.ShowEditingIcon = false;
            this.dataGridView.ShowRowErrors = false;
            this.dataGridView.Size = new System.Drawing.Size(976, 570);
            this.dataGridView.TabIndex = 17;
            // 
            // panelProgress
            // 
            this.panelProgress.BackColor = System.Drawing.SystemColors.ControlLight;
            this.panelProgress.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
            this.panelProgress.Controls.Add(this.labelMessage);
            this.panelProgress.Location = new System.Drawing.Point(218, 166);
            this.panelProgress.Name = "panelProgress";
            this.panelProgress.Padding = new System.Windows.Forms.Padding(2);
            this.panelProgress.Size = new System.Drawing.Size(509, 55);
            this.panelProgress.TabIndex = 18;
            // 
            // labelMessage
            // 
            this.labelMessage.BackColor = System.Drawing.Color.RoyalBlue;
            this.labelMessage.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelMessage.Font = new System.Drawing.Font("Arial", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelMessage.ForeColor = System.Drawing.Color.MistyRose;
            this.labelMessage.Location = new System.Drawing.Point(2, 2);
            this.labelMessage.Name = "labelMessage";
            this.labelMessage.Size = new System.Drawing.Size(503, 49);
            this.labelMessage.TabIndex = 0;
            this.labelMessage.Text = "正在查看日志信息。请稍等";
            this.labelMessage.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // panelSearch
            // 
            this.panelSearch.Controls.Add(this.buttonSaveToCVS);
            this.panelSearch.Controls.Add(this.uiMarkLabel2);
            this.panelSearch.Controls.Add(this.uiMarkLabel1);
            this.panelSearch.Controls.Add(this.ToDayPicker);
            this.panelSearch.Controls.Add(this.fromDayPicker);
            this.panelSearch.Controls.Add(this.buttonSearch);
            this.panelSearch.Controls.Add(this.txtTarget);
            this.panelSearch.Dock = System.Windows.Forms.DockStyle.Bottom;
            this.panelSearch.Font = new System.Drawing.Font("微软雅黑", 12F);
            this.panelSearch.Location = new System.Drawing.Point(0, 570);
            this.panelSearch.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
            this.panelSearch.MinimumSize = new System.Drawing.Size(1, 1);
            this.panelSearch.Name = "panelSearch";
            this.panelSearch.Size = new System.Drawing.Size(976, 40);
            this.panelSearch.TabIndex = 19;
            this.panelSearch.Text = null;
            this.panelSearch.TextAlignment = System.Drawing.ContentAlignment.MiddleCenter;
            this.panelSearch.ZoomScaleRect = new System.Drawing.Rectangle(0, 0, 0, 0);
            // 
            // buttonSaveToCVS
            // 
            this.buttonSaveToCVS.Cursor = System.Windows.Forms.Cursors.Hand;
            this.buttonSaveToCVS.Font = new System.Drawing.Font("微软雅黑", 12F);
            this.buttonSaveToCVS.Location = new System.Drawing.Point(828, 0);
            this.buttonSaveToCVS.MinimumSize = new System.Drawing.Size(1, 1);
            this.buttonSaveToCVS.Name = "buttonSaveToCVS";
            this.buttonSaveToCVS.Size = new System.Drawing.Size(100, 32);
            this.buttonSaveToCVS.Style = Sunny.UI.UIStyle.Custom;
            this.buttonSaveToCVS.StyleCustomMode = true;
            this.buttonSaveToCVS.Symbol = 61639;
            this.buttonSaveToCVS.TabIndex = 89;
            this.buttonSaveToCVS.Text = "保存";
            this.buttonSaveToCVS.TipsFont = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            this.buttonSaveToCVS.ZoomScaleRect = new System.Drawing.Rectangle(0, 0, 0, 0);
            this.buttonSaveToCVS.Click += new System.EventHandler(this.buttonSaveToCVS_Click);
            // 
            // uiMarkLabel2
            // 
            this.uiMarkLabel2.AutoSize = true;
            this.uiMarkLabel2.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            this.uiMarkLabel2.Location = new System.Drawing.Point(256, 7);
            this.uiMarkLabel2.Name = "uiMarkLabel2";
            this.uiMarkLabel2.Padding = new System.Windows.Forms.Padding(5, 0, 0, 0);
            this.uiMarkLabel2.Size = new System.Drawing.Size(79, 22);
            this.uiMarkLabel2.TabIndex = 88;
            this.uiMarkLabel2.Text = "结束时间";
            this.uiMarkLabel2.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            this.uiMarkLabel2.ZoomScaleRect = new System.Drawing.Rectangle(0, 0, 0, 0);
            // 
            // uiMarkLabel1
            // 
            this.uiMarkLabel1.AutoSize = true;
            this.uiMarkLabel1.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            this.uiMarkLabel1.Location = new System.Drawing.Point(3, 7);
            this.uiMarkLabel1.Name = "uiMarkLabel1";
            this.uiMarkLabel1.Padding = new System.Windows.Forms.Padding(5, 0, 0, 0);
            this.uiMarkLabel1.Size = new System.Drawing.Size(79, 22);
            this.uiMarkLabel1.TabIndex = 87;
            this.uiMarkLabel1.Text = "开始时间";
            this.uiMarkLabel1.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            this.uiMarkLabel1.ZoomScaleRect = new System.Drawing.Rectangle(0, 0, 0, 0);
            // 
            // ToDayPicker
            // 
            this.ToDayPicker.CalendarFont = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
            this.ToDayPicker.CalendarForeColor = System.Drawing.Color.DarkBlue;
            this.ToDayPicker.CalendarTrailingForeColor = System.Drawing.SystemColors.InactiveBorder;
            this.ToDayPicker.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
            this.ToDayPicker.Location = new System.Drawing.Point(367, 3);
            this.ToDayPicker.Name = "ToDayPicker";
            this.ToDayPicker.Size = new System.Drawing.Size(120, 29);
            this.ToDayPicker.TabIndex = 84;
            this.ToDayPicker.Value = new System.DateTime(2008, 9, 2, 0, 0, 0, 0);
            this.ToDayPicker.ValueChanged += new System.EventHandler(this.ToDayPicker_ValueChanged);
            // 
            // fromDayPicker
            // 
            this.fromDayPicker.CalendarFont = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.fromDayPicker.CalendarForeColor = System.Drawing.Color.DarkBlue;
            this.fromDayPicker.CalendarTrailingForeColor = System.Drawing.SystemColors.InactiveBorder;
            this.fromDayPicker.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
            this.fromDayPicker.Location = new System.Drawing.Point(103, 3);
            this.fromDayPicker.Name = "fromDayPicker";
            this.fromDayPicker.Size = new System.Drawing.Size(120, 29);
            this.fromDayPicker.TabIndex = 83;
            this.fromDayPicker.Value = new System.DateTime(2008, 9, 2, 0, 0, 0, 0);
            this.fromDayPicker.ValueChanged += new System.EventHandler(this.fromDayPicker_ValueChanged);
            // 
            // buttonSearch
            // 
            this.buttonSearch.Cursor = System.Windows.Forms.Cursors.Hand;
            this.buttonSearch.Font = new System.Drawing.Font("微软雅黑", 12F);
            this.buttonSearch.Location = new System.Drawing.Point(722, 0);
            this.buttonSearch.MinimumSize = new System.Drawing.Size(1, 1);
            this.buttonSearch.Name = "buttonSearch";
            this.buttonSearch.Size = new System.Drawing.Size(100, 32);
            this.buttonSearch.Style = Sunny.UI.UIStyle.Custom;
            this.buttonSearch.StyleCustomMode = true;
            this.buttonSearch.Symbol = 361442;
            this.buttonSearch.TabIndex = 82;
            this.buttonSearch.Text = "查询";
            this.buttonSearch.TipsFont = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            this.buttonSearch.ZoomScaleRect = new System.Drawing.Rectangle(0, 0, 0, 0);
            this.buttonSearch.Click += new System.EventHandler(this.buttonSearch_Click);
            // 
            // txtTarget
            // 
            this.txtTarget.ButtonWidth = 100;
            this.txtTarget.Cursor = System.Windows.Forms.Cursors.IBeam;
            this.txtTarget.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            this.txtTarget.Location = new System.Drawing.Point(494, 0);
            this.txtTarget.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
            this.txtTarget.MinimumSize = new System.Drawing.Size(1, 1);
            this.txtTarget.Name = "txtTarget";
            this.txtTarget.Padding = new System.Windows.Forms.Padding(5);
            this.txtTarget.ShowText = false;
            this.txtTarget.Size = new System.Drawing.Size(221, 32);
            this.txtTarget.TabIndex = 9;
            this.txtTarget.TextAlignment = System.Drawing.ContentAlignment.MiddleLeft;
            this.txtTarget.Watermark = "";
            this.txtTarget.ZoomScaleRect = new System.Drawing.Rectangle(0, 0, 0, 0);
            this.txtTarget.KeyUp += new System.Windows.Forms.KeyEventHandler(this.txtTarget_KeyUp);
            // 
            // uiPanel1
            // 
            this.uiPanel1.Controls.Add(this.dataGridView);
            this.uiPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
            this.uiPanel1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            this.uiPanel1.Location = new System.Drawing.Point(0, 0);
            this.uiPanel1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
            this.uiPanel1.MinimumSize = new System.Drawing.Size(1, 1);
            this.uiPanel1.Name = "uiPanel1";
            this.uiPanel1.Size = new System.Drawing.Size(976, 570);
            this.uiPanel1.TabIndex = 20;
            this.uiPanel1.Text = "uiPanel1";
            this.uiPanel1.TextAlignment = System.Drawing.ContentAlignment.MiddleCenter;
            this.uiPanel1.ZoomScaleRect = new System.Drawing.Rectangle(0, 0, 0, 0);
            // 
            // InformOperation
            // 
            this.Controls.Add(this.uiPanel1);
            this.Controls.Add(this.panelSearch);
            this.Controls.Add(this.panelProgress);
            this.Name = "InformOperation";
            this.Size = new System.Drawing.Size(976, 610);
            this.Paint += new System.Windows.Forms.PaintEventHandler(this.InformOperation_Paint);
            ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
            this.panelProgress.ResumeLayout(false);
            this.panelSearch.ResumeLayout(false);
            this.panelSearch.PerformLayout();
            this.uiPanel1.ResumeLayout(false);
            this.ResumeLayout(false);

        }
    }
}
